%h5.prepend-top-0
  已经保护的 (#{@protected_branches.size})
- if @protected_branches.empty?
  %p.settings-message.text-center
    没有保存分支，请在上面选择一个分支保护。
- else
  - can_admin_project = can?(current_user, :admin_project, @project)
  .table-responsive
    %table.table.protected-branches-list
      %colgroup
        %col{ width: "20%" }
        %col{ width: "30%" }
        %col{ width: "25%" }
        %col{ width: "25%" }
        - if can_admin_project
          %col
      %thead
        %tr
          %th 保护分支
          %th 提交
          %th 开发者可以推送
          %th 开发者可以合并
          - if can_admin_project
            %th
      %tbody
        = render partial: @protected_branches, locals: { can_admin_project: can_admin_project }

  = paginate @protected_branches, theme: 'gitlab'
